home *** CD-ROM | disk | FTP | other *** search
Wrap
XXXXmmmmeeeeAAAAddddddddFFFFooooccccuuuussssCCCChhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk((((llllUUUUXXXXiiiiNNNNmmmmbbbbIIIIeeeerrrrXXXXAAAAaaaaddddrrrrSSSSddddyyyyyyyyFFFFssssooooccccttttccccaaaaeeeeuuuullllmmmmssssllllCCCC))))VVVVhhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk((((lllliiiibbbbrrrraaaarrrryyyy ccccaaaallllllll)))) NNNNAAAAMMMMEEEE XXXXmmmmeeeeAAAAddddddddFFFFooooccccuuuussssCCCChhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk - Registers a callback for focus changes SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS #include <Xm/VendorSEP.h> vvvvooooiiiidddd XXXXmmmmeeeeAAAAddddddddFFFFooooccccuuuussssCCCChhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk( WWWWiiiiddddggggeeeetttt wwwwiiiiddddggggeeeetttt, XXXXttttCCCCaaaallllllllbbbbaaaacccckkkkPPPPrrrroooocccc ccccaaaallllllllbbbbaaaacccckkkk____pppprrrroooocccceeeedddduuuurrrreeee, XXXXttttPPPPooooiiiinnnntttteeeerrrr ddddaaaattttaaaa); DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN XXXXmmmmeeeeAAAAddddddddFFFFooooccccuuuussssCCCChhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk registers a _c_a_l_l_b_a_c_k__p_r_o_c_e_d_u_r_e to be called whenever there is a focus change to any widget in the widget tree managed by a specified VVVVeeeennnnddddoooorrrrSSSShhhheeeellllllll or subclass of VVVVeeeennnnddddoooorrrrSSSShhhheeeellllllll. This _c_a_l_l_b_a_c_k__p_r_o_c_e_d_u_r_e is called the focus change callback. Motif will not call the focus change callbacks when the VVVVeeeennnnddddoooorrrrSSSShhhheeeellllllll (or subclass) is in implicit mode. In explicit mode, Motif automatically calls the focus change callbacks whenever the user or the application attempts to change focus. Your focus change callback procedure has the option of accepting or rejecting the attempted focus change. Registering a focus change callback can cause an entire application to run more slowly because the focus change callbacks might be called fairly frequently. A focus change callback can be removed by calling XXXXmmmmeeeeRRRReeeemmmmoooovvvveeeeFFFFooooccccuuuussssCCCChhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk. _w_i_d_g_e_t Specifies the widget whose children are to be monitored for focus changes. The specified _w_i_d_g_e_t must be a VVVVeeeennnnddddoooorrrrSSSShhhheeeellllllll or a subclass of VVVVeeeennnnddddoooorrrrSSSShhhheeeellllllll. _c_a_l_l_b_a_c_k__p_r_o_c_e_d_u_r_e Specifies the callback procedure to be called whenever there is a focus change. _d_a_t_a Specifies the call data to be passed as the _c_a_l_l__d_a_t_a argument to the callback procedure. Motif passes a pointer to an XXXXmmmmFFFFooooccccuuuussssMMMMoooovvvveeeeddddCCCCaaaallllllllbbbbaaaacccckkkkSSSSttttrrrruuuucccctttt to _c_a_l_l_b_a_c_k__p_r_o_c_e_d_u_r_e. When _c_a_l_l_b_a_c_k__p_r_o_c_e_d_u_r_e returns, Motif examines the _c_o_n_t field only. typedef struct { int _r_e_a_s_o_n ;;;; XXXXEEEEvvvveeeennnntttt ****_e_v_e_n_t;;;; BBBBoooooooolllleeeeaaaannnn _c_o_n_t;;;; Page 1 (printed 10/3/02) XXXXmmmmeeeeAAAAddddddddFFFFooooccccuuuussssCCCChhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk((((llllUUUUXXXXiiiiNNNNmmmmbbbbIIIIeeeerrrrXXXXAAAAaaaaddddrrrrSSSSddddyyyyyyyyFFFFssssooooccccttttccccaaaaeeeeuuuullllmmmmssssllllCCCC))))VVVVhhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk((((lllliiiibbbbrrrraaaarrrryyyy ccccaaaallllllll)))) WWWWiiiiddddggggeeeetttt _o_l_d__f_o_c_u_s;;;; WWWWiiiiddddggggeeeetttt _n_e_w__f_o_c_u_s;;;; uuuunnnnssssiiiiggggnnnneeeedddd cccchhhhaaaarrrr _f_o_c_u_s__p_o_l_i_c_y;;;; XXXXmmmmTTTTrrrraaaavvvveeeerrrrssssaaaallllDDDDiiiirrrreeeeccccttttiiiioooonnnn _d_i_r_e_c_t_i_o_n;;;; }}}} XXXXmmmmFFFFooooccccuuuussssMMMMoooovvvveeeeddddCCCCaaaallllllllbbbbaaaacccckkkkSSSSttttrrrruuuucccctttt;;;; _r_e_a_s_o_n Indicates why the callback was invoked. Motif always sets this field to XXXXmmmmCCCCRRRR____FFFFOOOOCCCCUUUUSSSS____MMMMOOOOVVVVEEEEDDDD. _e_v_e_n_t Points to the event that triggered the callback. _c_o_n_t Indicates whether an attempted focus change will be allowed or rejected. A focus change callback should set _c_o_n_tto True (the default) to permit the focus change. A focus change callback should set _c_o_n_t to False to reject the focus change. Therefore, if you set _c_o_n_t to False, Motif will ensure that the focus stays at widget _o_l_d__f_o_c_u_s. _o_l_d__f_o_c_u_s Indicates the widget ID of the widget that had keyboard focus immediately prior to the most recent traversal. _n_e_w__f_o_c_u_s Indicates the widget ID of the widget that has just gotten keyboard focus. _f_o_c_u_s__p_o_l_i_c_y Indicates the VVVVeeeennnnddddoooorrrrSSSShhhheeeellllllll's keyboard focus policy; this will always be XXXXmmmmEEEEXXXXPPPPLLLLIIIICCCCIIIITTTT since _c_a_l_l_b_a_c_k__p_r_o_c_e_d_u_r_e only gets called in explicit mode. _d_i_r_e_c_t_i_o_n Specifies the direction of the traversal. (See XXXXmmmmPPPPrrrroooocccceeeessssssssTTTTrrrraaaavvvveeeerrrrssssaaaallll(3) in the _M_o_t_i_f _P_r_o_g_r_a_m_m_e_r'_s _R_e_f_e_r_e_n_c_efor details on possible values of the XXXXmmmmTTTTrrrraaaavvvveeeerrrrssssaaaallllDDDDiiiirrrreeeeccccttttiiiioooonnnn enumerated type.) RRRREEEELLLLAAAATTTTEEEEDDDD XXXXmmmmeeeeRRRReeeemmmmoooovvvveeeeFFFFooooccccuuuussssCCCChhhhaaaannnnggggeeeeCCCCaaaallllllllbbbbaaaacccckkkk(3). Page 2 (printed 10/3/02)